package com.fulihui.information.util;

import org.near.toolkit.common.DateUtils;

import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.Date;

/**
 * Date转LocalDateTime
 * Created by LeeSon on 2016/12/26 0026.
 */
public class DateKit {
    public static LocalDateTime parse(Date date, String pattern) {
        return null == date ? null
            : LocalDateTime.parse(DateUtils.formatNewFormat(date),
                DateTimeFormatter.ofPattern(DateUtils.newFormat));
    }
}